package test7;

public class Rectangle {
    private double length;
    private double width;

    public Rectangle() {
        this.length =0.0;
        this.width = 0.0;
    }

    public void setXy(double length,double width){
        this.length=length;
        this.width=width;
    }

    public double getArea(){
        return this.length*this.width;
    }

    public double getPerimeter(){
        return this.length+this.width+this.length+this.width;
    }

    public double getLength() {
        return length;
    }

    public void setLength(double length) {
        this.length = length;
    }

    public double getWidth() {
        return width;
    }

    public void setWidth(double width) {
        this.width = width;
    }
}
